/*
 * Properties.h
 *
 *  Created on: Mar 24, 2011
 *      Author: kimi
 */

#include <stdlib.h>
#include <string.h>
#include <iostream>
#include <fstream>
#include "Property.h"
#include "../Utils/StringUtils.h"

#ifndef PROPERTIES_H_
#define PROPERTIES_H_

using namespace std;

class Properties {

public:

	Properties(string filePath);
	bool load();
	bool save();

	string get(string key);
	bool put(string key, string value);

	string remove(string key);

	unsigned int getInt(string key);
	bool putInt(string key, unsigned int value);

	//~Properties();

private:

	void reload(void);

	string filePath;
	bool loaded;
	Property *properties;
	int propNum;

	bool dirty;
};

#endif /* PROPERTIES_H_ */
